home *** CD-ROM | disk | FTP | other *** search
/ Champak 146 / (Vol 146) Jan 07 2012.iso / Games / shark_attack_2.swf / scripts / DefineSprite_49 / frame_1 / DoAction.as
Encoding:
Text File  |  2012-01-07  |  463 b   |  11 lines

  1. x = _parent._x + _parent._parent._x;
  2. y = _parent._y + _parent._parent._y;
  3. if(_root.mascot.air == true && _root.mascot.jumping != true && (x < _root.mascot._x + 30 && _root.mascot._x - 30 < x) && (y < _root.mascot._y + 50 && _root.mascot._y < y))
  4. {
  5.    _root.mascot.jumpspeed = _root.mascot.jumpspeed_max;
  6.    _root.mascot.jumping = true;
  7.    _root.mascot.dest_y = _root.mascot._y - 80;
  8.    _root.mascot.gotoAndStop("jump");
  9.    _parent.gotoAndStop("die");
  10. }
  11.